//
//  CZLabel.m
//  ColorBlend
//
//  Created by apple on 15-1-13.
//  Copyright (c) 2015年 itcast. All rights reserved.
//

#import "CZLabel.h"

@implementation CZLabel


// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
    // Drawing code
    
    [super drawRect:rect];
    
    //画一个矩形的几种方式:
    //1.CGContextAddRect
    //2.UIBeitherPath
    //3.UIRectFill
    //上为D 下为S
    //R=D.a*S;
    

    [[UIColor redColor]setFill];
//    UIRectFillUsingBlendMode(CGRectMake(0, 0, rect.size.width*0.5, rect.size.height), kCGBlendModeSourceIn);
    
    UIRectFillUsingBlendMode(CGRectMake(0, 0, rect.size.width*0.6, rect.size.height), kCGBlendModeSourceOut);
    
}


@end
